#ifndef __ARCH_HW_TIME_H__
#define __ARCH_HW_TIME_H__

#include "kernel/time.h"

#ifdef __cplusplus
extern "C" {
#endif

#define LATCH  				((1193180 + HZ / 2) / HZ)

#define	CMOS_PORT			(0x70)
#define	CMOS_REGA			(0x0A)
#define UPDATE_F			(0x80)

#define	CMOS_SEC			(0x00 | 0x80)
#define	CMOS_MIN			(0x02 | 0x80)
#define	CMOS_HOUR			(0x04 | 0x80)
#define	CMOS_WEEK			(0x06 | 0x80)
#define	CMOS_DAY			(0x07 | 0x80)
#define	CMOS_MONTH			(0x08 | 0x80)
#define	CMOS_YEAR			(0x09 | 0x80)
#define	CMOS_CENTRY			(0x32 | 0x80)

// initialization of the chip
void init_8253(void);

#ifdef __cplusplus
}
#endif
#endif
/* EOF */
